package com.gy.hsim.bservice.framework.mapper;

import java.util.List;

import com.gy.hsim.bservice.userGroupingManagement.bean.Team;

/**
 * 
 * @ClassName: TeamMapper 
 * @Description: 好友分组DAO接口
 * @author Lee 
 * @date 2015-1-13 下午5:54:30
 */
public interface TeamMapper {
	//添加分组接口
	public int addTeam(Team team) throws Exception;
	
	//根据用户账号查询所有分组接口
	public List<Team> queryTeamInfoByUserId(Team team) throws Exception;
	
	//在用户方查询好友是否把用户拉黑,大于0表示已经拉黑
	public int queryFriendSetUserBlacklistedByUserWay(Team team) throws Exception;
	
	//在好友方查询好友是否把用户拉黑,大于0表示已经拉黑
	public int queryFriendSetUserBlacklistedByFriendWay(Team team) throws Exception;
	
	//更新分组信息接口
	public int updateTeamInfo(Team team) throws Exception;
	
	//删除分组接口
	public int deleteTeam(Team team) throws Exception;
	
	//在用户方把好友添加到 分组中
	//public int addFriendIntoTeamByUserWay(Team team) throws Exception;
	public int addFriendIntoTeamByUserWay(List<Team> team) throws Exception;
	
	//在好友方把好友添加到 分组中
	//public int addFriendIntoTeamByFriendWay(Team team) throws Exception;
	public int addFriendIntoTeamByFriendWay(List<Team> team) throws Exception;
	
	//删除分组后在用户方更新好友分组为空
	public int updateTeamsetAfterDeleteTeamByUserWay(Team team) throws Exception;
	
	//删除分组后在好友方更新好友分组为空
	public int updateTeamsetAfterDeleteTeamByFriendWay(Team team) throws Exception;
	
	//查询用户创建的分组个数
	public int getTotalTeamsUserCreate (Team team) throws Exception;
	
	//查询用户是否创建过分组名
	public int teamNameCount (Team team) throws Exception;
}
